from dash.dependencies import Input, Output
import dash_html_components as html
import dash_core_components as dcc
import plotly

from app import app
from datas.SzHouseData import HouseData

Sz = HouseData()
# data = Sz.data
Cdata = Sz.jd()
# print(Cdata[0].index)

layout = html.Div([
    dcc.Graph(
        id='example-graph',
        figure={
        'data':[
            {'y' : Cdata[0].index,
            'x': Cdata[0].values,
             'type':'bar',
             'text':Cdata[0].values,
             'textposition':'outside',
             'orientation':'h'

            }
        ],
        'layout':{
            'title': Cdata[1]
        }
    },
    style={

    }
    )

])
